package com.rts.service;

import com.rts.common.CommonResult;
import com.rts.dto.UserInfoDTO;
import com.rts.mapper.UserInfoMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 用户服务
 */
@Service
@Slf4j
public class UserInfoService {

    @Autowired
    private UserInfoMapper userInfoMapper;

    /**
     * 获取用户列表
     * @return
     */
    public CommonResult getList(){

        List<UserInfoDTO> userInfoDTOList = userInfoMapper.getList();
        return CommonResult.ok().addData(userInfoDTOList);

    }


}
